package com.quantgroup.data.entity.valobj;

import lombok.Getter;

/**
 * 热云AppKey常量类
 *
 * @author osmondy
 * @create 2021/10/3 13:42
 */
@Getter
public enum AppKeyEnum {
    /**
     * Android key
     */
    ANDROID_KEY("3681b6a12a35fe301bd6b0b8cf4a94fe", "199d6eb8b537e250f84452e0a86a0f40"),
    /**
     * iOS key
     */
    IOS_KEY("48131e5e7969cc155b70f766790cb35a", "6fc9e52d28ed4e1eb3b8495126ce5d2a"),
    /**
     * wx Key
     */
    WX_KEY("68a35d6d6e48de2c1cf8a9bb15215a71", "4b1340f9a86216bd0983846e369843ed");

    private String key;
    private String security;

    AppKeyEnum(String key, String security) {
        this.key = key;
        this.security = security;
    }

    /**
     * 根据 str 获取对应枚举对象
     *
     * @param str
     * @return
     */
    public static AppKeyEnum getAppKey(String str) {
        for (AppKeyEnum appKeyEnum : AppKeyEnum.values()) {
            if (appKeyEnum.key.equals(str)) {
                return appKeyEnum;
            }
        }
        return null;
    }


}
